.. _CSound Class: ========================== CSound Class ========================== .. toctree:: :maxdepth: 1 * :ref:`Overview` * :ref:`Quick Reference` * :ref:`Constructors` * :ref:`Methods` ---- .. _CSound_Overview: Overview --------------- .. note:: The **CSound** class handles The structure used for this class is :ref:`CSound` ---- .. _CSound_QuickRef: Quick Reference --------------- +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | **Quick Ref** | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:CSound**\(:ref:`CResRef` cNewRef, int nNewRange, int nNewChannel, int nNewLooping, int nNewPriority, int bNewPositionedSound) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:CSound**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | virtual void **CSound\:\:~CSound**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:ExclusivePlay**\(int bReplay) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | unsigned int **CSound\:\:GetArea**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | unsigned int **CSound\:\:GetBuffer**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:GetChannel**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:GetLooping**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | unsigned long **CSound\:\:GetPlayTime**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:GetPriority**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:GetRangeVolume**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`CResWave`\* **CSound\:\:GetRes**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`CResRef`\& **CSound\:\:GetResRef**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:GetSource**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | long **CSound\:\:GetVolume**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:IsSoundPlaying**\(unsigned char bInSoundUpdate) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | virtual int __cdecl **CSound\:\:IsSourcePlaying**\(int source) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:Play**\(int bReplay) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:Play**\(int nNewXCoordinate, int nNewYCoordinate, int nNewZCoordinate, int bReplay) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:PlayWaiting**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:ReleaseSound**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | virtual void __cdecl **CSound\:\:ReleaseSound**\(int source, int buffer) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:ResetVolume**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:SetChannel**\(int nNewChannel, unsigned int nArea) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:SetCoordinates**\(int nNewXCoordinate, int nNewYCoordinate, int nNewZCoordinate) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:SetFireForget**\(int bNewFireForget) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:SetFrequency**\(unsigned long dwNewFrequency) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:SetLoopingFlag**\(int nNewLooping) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:SetPitchVariance**\(long nPitchVar) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:SetPriority**\(unsigned char nPriority) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:SetRange**\(int nNewRange) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:SetResRef**\(:ref:`CResRef`\& cNewResRef, int bSetAutoRequest, int bWarningIfMissing) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:SetVolume**\(long nNewVolume) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void **CSound\:\:SetVolumeVariance**\(long nVolVar) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | unsigned char **CSound\:\:SoundDuckedOthers**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | int **CSound\:\:Stop**\() | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ | virtual void __cdecl **CSound\:\:StopSource**\(int source) | +--------------------------------------------------------------------------------------------------------------------------------------------------------------+ ---- .. _CSound_Constructors: Constructors --------------- +-----------------------------------------+------------------------------------------------------+ | **Name** | **Description** | +-----------------------------------------+------------------------------------------------------+ | :ref:`CSound\:\:CSound` | Constructs a ``CSound`` object | +-----------------------------------------+------------------------------------------------------+ | :ref:`CSound\:\:CSound` | Destroys a ``CSound`` object | +-----------------------------------------+------------------------------------------------------+ .. _CSoundCSound: CSound\:\:CSound ^^^^^^^^^^^^^^^^^^^^^^^^^ Constructs a ``CSound`` object :: void CSound::CSound( CResRef cNewRef, int nNewRange, int nNewChannel, int nNewLooping, int nNewPriority, int bNewPositionedSound); **Parameters** * :ref:`CResRef` *cNewRef* - * ``int`` *nNewRange* - * ``int`` *nNewChannel* - * ``int`` *nNewLooping* - * ``int`` *nNewPriority* - * ``int`` *bNewPositionedSound* - **Remarks** Constructs a ``CSound`` object ---- CSound\:\:CSound ^^^^^^^^^^^^^^^^^^^^^^^^^ Constructs a ``CSound`` object :: void CSound::CSound(); **Remarks** Constructs a ``CSound`` object ---- .. _CSound~CSound: CSound\:\:~CSound ^^^^^^^^^^^^^^^^^^^^^^^^^ Destroys the ``CSound`` object :: virtual void CSound::~CSound(); **Remarks** Destroys the ``CSound`` object ---- .. _CSound_Methods: Methods --------------- +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | **Name** | **Description** | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:ExclusivePlay` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetArea` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetBuffer` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetChannel` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetLooping` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetPlayTime` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetPriority` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetRangeVolume` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetRes` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetResRef` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetSource` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:GetVolume` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:IsSoundPlaying` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:IsSourcePlaying` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:Play` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:Play` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:PlayWaiting` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:ReleaseSound` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:ReleaseSound` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:ResetVolume` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetChannel` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetCoordinates` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetFireForget` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetFrequency` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetLoopingFlag` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetPitchVariance` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetPriority` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetRange` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetResRef` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetVolume` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SetVolumeVariance` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:SoundDuckedOthers` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:Stop` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ | :ref:`CSound\:\:StopSource` | | +-------------------------------------------------------------+-----------------------------------------------------------------------------------------+ ---- .. _CSoundExclusivePlay: CSound\:\:ExclusivePlay ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetArea: CSound\:\:GetArea ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetBuffer: CSound\:\:GetBuffer ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetChannel: CSound\:\:GetChannel ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetLooping: CSound\:\:GetLooping ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetPlayTime: CSound\:\:GetPlayTime ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetPriority: CSound\:\:GetPriority ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetRangeVolume: CSound\:\:GetRangeVolume ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetRes: CSound\:\:GetRes ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetResRef: CSound\:\:GetResRef ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetSource: CSound\:\:GetSource ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundGetVolume: CSound\:\:GetVolume ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundIsSoundPlaying: CSound\:\:IsSoundPlaying ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundIsSourcePlaying: CSound\:\:IsSourcePlaying ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundPlay: CSound\:\:Play ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: int **CSound\:\:Play**\(int bReplay); **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- CSound\:\:Play ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: int **CSound\:\:Play**\(int nNewXCoordinate, int nNewYCoordinate, int nNewZCoordinate, int bReplay); **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundPlayWaiting: CSound\:\:PlayWaiting ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundReleaseSound: CSound\:\:ReleaseSound ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: void **CSound\:\:ReleaseSound**\(); **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- CSound\:\:ReleaseSound ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: virtual void __cdecl **CSound\:\:ReleaseSound**\(int source, int buffer); **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundResetVolume: CSound\:\:ResetVolume ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetChannel: CSound\:\:SetChannel ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetCoordinates: CSound\:\:SetCoordinates ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetFireForget: CSound\:\:SetFireForget ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetFrequency: CSound\:\:SetFrequency ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetLoopingFlag: CSound\:\:SetLoopingFlag ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetPitchVariance: CSound\:\:SetPitchVariance ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetPriority: CSound\:\:SetPriority ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetRange: CSound\:\:SetRange ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetResRef: CSound\:\:SetResRef ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetVolume: CSound\:\:SetVolume ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSetVolumeVariance: CSound\:\:SetVolumeVariance ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundSoundDuckedOthers: CSound\:\:SoundDuckedOthers ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundStop: CSound\:\:Stop ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks** ---- .. _CSoundStopSource: CSound\:\:StopSource ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ :: x; **Parameters** * * - * * - * * - * * - **Return Value** Returns **Remarks**